<!DOCTYPE html SYSTEM "http://www.thymeleaf.org/dtd/xhtml1-strict-thymeleaf-4.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xmlns:th="http://www.thymeleaf.org">

<div class="layui-card-body" th:fragment="query">

    <!--每个zmn-form-item一行，每行4列
        支持页面自适应，1280分辨率下不折行
        -->
    <div class="zmn-form-item">
        <div class="item-inline">
            <label class="inline-label">业务类型：</label>
            <div class="inline-box">
                <div class="inline-box-cc">
                    <div class="box-input-inline">
                        <select id="bizType" name="bizType" lay-search="">
                            <option value="0">-选择-</option>
                            <option th:each="bizType:${bizTypeList}" th:value="${bizType.key}"
                                    th:selected="${vo.bizType == bizType.key}"
                                    th:text="${bizType.value}"/>
                        </select>
                    </div>
                </div>
            </div>
        </div>
        <div class="item-inline">
            <label class="inline-label">服务分类：</label>
            <div class="inline-box">
                <div class="inline-box-cc">
                    <div class="box-input-inline">
                        <select id="servCategId" name="servCategId" lay-filter="servCategId" value="0" lay-search>
                            <option value="0" th:selected="${0 == vo.servCategId}">-选择-</option>
                            <option th:value="${item.categId}" th:selected="${item.categId == vo.servCategId}"
                                    th:text="${item.showName}"
                                    th:each="item:${servCategories}">分类
                            </option>
                        </select>
                    </div>
                </div>
            </div>
        </div>

        <div class="item-inline">
            <label class="inline-label">前台分类：</label>
            <div class="inline-box">
                <div class="inline-box-cc">
                    <div class="box-input-inline">
                        <select id="categOneId" name="categOneId" lay-filter="categOneId" value="0" lay-search>
                            <option value="0" th:selected="${0 == vo.categOneId}">-选择-</option>
                            <option th:value="${item.categId}" th:selected="${item.categId == vo.categOneId}"
                                    th:text="${item.name}"
                                    th:each="item:${baseCategories}">分类
                            </option>
                        </select>
                    </div>
                </div>
            </div>
        </div>

        <div class="item-inline">
            <!--<label class="inline-label">二级分类：</label>-->
            <div class="inline-box">
                <div class="inline-box-cc" style="margin-left: 5px">
                    <div class="box-input-inline">
                        <select id="categId" name="categId" lay-filter="categId" value="0" lay-search>
                            <option value="0" th:selected="${0 == vo.categId}">-选择-</option>
                            <option th:value="${item.categId}" th:selected="${item.categId == vo.categId}"
                                    th:text="${item.categName}"
                                    th:each="item:${baseCategoryTwoList}">分类
                            </option>
                        </select>
                    </div>
                </div>
            </div>
        </div>

    </div>
    <div class="zmn-form-item">

        <div class="item-inline">
            <label class="inline-label">ID/名称：</label>
            <div class="inline-box">
                <div class="inline-box-cc">
                    <!--默认情况下标签box-input-inline占满整个inline-box-cc标签-->
                    <div class="box-input-inline">
                        <input type="text" name="name" th:value="${vo.name}" placeholder="请输入ID/名称" autocomplete="off"
                               class="layui-input"
                               maxlength="45"/>
                    </div>
                </div>
            </div>
        </div>
        <div class="item-inline">
            <label class="inline-label">后台产品：</label>
            <div class="inline-box">
                <div class="inline-box-cc">
                    <div class="box-input-inline">
                        <select id="backProductId" name="backProductId" lay-filter="backProductId" value="0" lay-search>
                            <option value="0" th:selected="${0 == vo.backProductId}">-选择-</option>
                            <option th:value="${item.productId}" th:selected="${item.productId == vo.backProductId}"
                                    th:text="${item.name}"
                                    th:each="item:${backProducts}">
                            </option>
                        </select>
                    </div>
                </div>
            </div>
        </div>
        <div class="item-inline">
            <label class="inline-label">状态：</label>
            <div class="inline-box">
                <div class="inline-box-cc">
                    <div class="box-input-inline">
                        <select id="status" name="status" value="0" lay-search>
                            <option value="0" th:selected="${0 == vo.status}">-选择-</option>
                            <option value="1" th:selected="${vo.status == 1}">下架</option>
                            <option value="2" th:selected="${vo.status == 2}">上架</option>
                        </select>
                    </div>
                </div>
            </div>
        </div>

        <div class="item-inline">
            <label class="inline-label">默认产品：</label>
            <div class="inline-box">
                <div class="inline-box-cc">
                    <div class="box-input-inline">
                        <select id="defaultType" name="defaultType" value="0">
                            <option value="0" th:selected="${0 == vo.defaultType||null==vo.defaultType}">-选择-</option>
                            <option value="2" th:selected="${vo.defaultType == 2}">默认</option>
                            <option value="1" th:selected="${vo.defaultType == 1}">非默认</option>
                        </select>
                    </div>
                </div>
            </div>
        </div>
    </div>
    <div class="zmn-form-item">
        <div class="item-inline">
            <label class="inline-label">产品类型：</label>
            <div class="inline-box">
                <div class="inline-box-cc">
                    <div class="box-input-inline">
                        <select id="productType" name="productType" lay-search="">
                            <option value="0">-选择-</option>
                            <option th:each="productType:${productTypes}" th:value="${productType.key}"
                                    th:selected="${vo.productType == productType.key}"
                                    th:text="${productType.value}"/>
                        </select>
                    </div>
                </div>
            </div>
        </div>
        <div class="item-inline">
            <label class="inline-label">使用渠道：</label>
            <div class="inline-box">
                <div class="inline-box-cc">
                    <div class="box-input-inline">
                        <select id="channelId" name="channelId" lay-search="">
                            <option value="0">-选择-</option>
                            <option th:each="channel:${channelList}" th:value="${channel.channelId}"
                                    th:selected="${vo.channelId == channel.channelId}"
                                    th:text="${channel.name}"/>
                        </select>
                    </div>
                </div>
            </div>
        </div>
        <div class="item-submit">
            <button class="layui-btn layui-btn-sm" lay-submit="" lay-filter="zmn-form-submit"><i class="layui-icon">&#xe615;</i>
            </button>
            <button type="reset" class="layui-btn layui-btn-primary layui-btn-sm"><i class="layui-icon">&#xe669;</i>
            </button>
            <button class="layui-btn d-button" lay-submit lay-filter="query-export" id="query-export"
                    style="display: none">导出
            </button>
        </div>
    </div>
</div>